import React from 'react'

import type { FC, ReactNode } from 'react'
import { memo } from 'react'
import { useRoutes } from 'react-router-dom'
import { Suspense } from 'react'
import router from './router'

interface Iprops {
  children?: ReactNode
}
const App: FC<Iprops> = () => {
  return (
  	<>
  	  <Suspense fallback={<div style={{padding: 16}}>加载中...</div>}>
  	    {useRoutes(router)}
  	  </Suspense>
  	</>
  )
}
export default memo(App)
